-
Notifications
You must be signed in to change notification settings - Fork 63
[BLOG] Add 'one year of free-threaded Python' post #916
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
|
The performance optimizations to the free-threaded GC are noteworthy, IMHO. The free-threaded build uses it's own cyclic GC implementation. I added two optimizations to the collection process in 3.14: mark-alive pass and pre-fetching (used only within mark-alive pass). Times below are from my "gc_big_tree.py" benchmark. The performance benefit will depend on the workload and this benchmark is kind of a best case scenario (large and complex object graph, causing traversal to visit many scattered locations in memory).
It was a small piece of code but the deferring of full collections also can give a significant speedup. On the toy list append benchmark in the issue, it makes it run 10 times faster (0.2 seconds vs 2 seconds). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @ngoldbaum! Looks good! I left some comments inline.
Also, one "bigger" suggestion: Could we may be more succinct in describing what free-threaded Python is? There's loads of resources on that everywhere and I'm not sure we should be iterating that here. I think it'd be best if we only provided a very very high-level overview (effectively before: GIL was protecting us, now: it isn't) and then link to one of those resources, maybe even @rgommers's blog post from last year.
|
I threw in an image from the talk but I don't think it looks very good in the blog. Would very much appreciate alternate suggestions for graphics. |
How about adding one of graphs I posted about scaling asyncio across threads? The blogpost mentions scaling of asyncio so adding that would be good to have. |
Thanks for the suggestion. I ended up going with a bit of AI-generated art - I felt like having graphs at the top of the post would distract a bit. We should highlight your work on asyncio in its own blog post IMO. |
Apply suggestions from code review Co-authored-by: gabalafou <[email protected]> Co-authored-by: Lysandros Nikolaou <[email protected]> respond to review, add image add link to PyCon abstract use a different image and add link to meta blog post use a smaller image
5ab01f3 to
c426e7f
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Α few more suggestions from a second read and I think it's good to go.
Co-authored-by: Lysandros Nikolaou <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good to go on my end!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @ngoldbaum & all reviewers! This looks about ready to go. I pushed some minor editorial edits, and there's one larger thing that deserves some attention: it's important to not claim too much of the credit and say "we have ...." unless it was actually us. I made two suggested edits that should address this. I think we've done something like 50% of all the heavy lifting over the past year on widely used OSS packages, so let's recognize that other half.
Co-authored-by: Ralf Gommers <[email protected]>
|
Done, thanks for the dose of humility! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great, in it goes - should be live in 5 minutes or so!
Add a blog post describing the work from the nogil team over the past year.
Suggestions for header images to go with this are very appreciated, along with review of the text.
Text styling
Non-text contents